package com.nercel.dsj.gksales.shiro.filter;

import com.nercel.dsj.gksales.shiro.util.ShiroUtil;
import org.apache.shiro.web.filter.authc.UserFilter;

import javax.servlet.ServletRequest;

/**
 * @author sunlin
 * @date 2018-11-20
 */
public class RestUserFilter extends UserFilter {

    @Override
    protected boolean pathsMatch(String path, ServletRequest request) {
        String realPath = ShiroUtil.getRealPath(path, request);
        return realPath != null && super.pathsMatch(realPath, request);
    }


}
